<?php 
//新闻分类的删除
	include_once("./com.php");
	$ne_cid=$_GET['ne_cid'];
	$set="select * from news_cate where ne_fid=$ne_cid";
	$res=mysql_query($set);
	if(mysql_num_rows($res)==0){
		$ser="delete from news_cate where ne_cid=$ne_cid";
		mysql_query($ser);
			if(mysql_affected_rows()>0){
				echo "<script>
						alert('删除成功')
						location.href='news_cate.php'
					</script>";
			}else{
				echo "<script>
						alert('删除失败')
						location.href='news_cate.php'
					</script>";
			}
	}else{
		echo "<script>
				alert('删除失败存在子分类')
				location.href='news_cate.php'
			</script>";
	}
	


 ?>
